using System;
using System.Collections.Generic;
using System.Text;

namespace DslCrossModelFramework {
    /// <summary>
    /// Used to signify if a model element serializes its id or not
    /// </summary>
    [AttributeUsage(AttributeTargets.Class, AllowMultiple=false, Inherited=true)]
    public class DslElementMetaDataAttribute : Attribute {
        /// <summary>
        /// Instantiates a new instance of <see cref="DslElementMetaDataAttribute"/>
        /// </summary>
        /// <param name="serializesId"><c>true</c> if the id of the model element is serialized; otherwise <c>false</c></param>
        /// <param name="hasElementName">if set to <c>true</c> the domain class has an element name property.</param>
        /// <param name="hasMonikerKey">if set to <c>true</c> the domain class has a moniker key property.</param>
        public DslElementMetaDataAttribute(bool serializesId, bool hasElementName, bool hasMonikerKey) {
            this.serializesId = serializesId;
            this.hasElementName = hasElementName;
            this.hasMonikerKey = hasMonikerKey;
        }

        private readonly bool serializesId = false;
        /// <summary>
        /// Returns <c>true</c> if the id of the model element is serialized; otherwise <c>false</c>
        /// </summary>
        public bool SerializesId {
            get { return serializesId; }
        }

        private readonly bool hasElementName = false;
        /// <summary>
        /// Returns <c>true</c> if the model element has an element name property; otherwise <c>false</c>
        /// </summary>
        public bool HasElementName {
            get { return hasElementName; }
        }

        private readonly bool hasMonikerKey = false;
        /// <summary>
        /// Returns <c>true</c> if the model element has a moniker key property; otherwise <c>false</c>
        /// </summary>
        public bool HasMonikerKey {
            get { return hasMonikerKey; }
        }
    }
}
